var serTab = {
	"cus": "私人定制",
	"ser": "预约服务"
}
var Index = {
	init: function(footer){
		footer && $("body").append(Init.getFootHtml);//是否需要页脚
		var mySwiper = new Swiper('.swiper-container',{
		    loop: true,
			autoplay: 3000,
			pagination : '.swiper-pagination',
			paginationClickable: true,
			onImagesReady: function(){
				var $img = $(".swiper-slide>img");
				$img.height($img.width()*8/16);
			}
	  	});
	  	$("body").on("click",".sicos",function(){
	  		Main.jump("service_detail.html");
	  	});
	  	$(".leftBtn.city").click(function(){
	  		Main.jump("city.html");
	  	});
	  	Index.searchInit();
	},
	customInit: function(){
		var title = serTab[Main.getQueryString("serTab")] || serTab["ser"];
		$(".title").text(title);
		$(".addImgBtn").on("click", function(){
			$(".cus_btm_list").prepend('<li class="cus_btm_img ub-img addImgBtn" style="background-image:url(../dist/images/banner.png)"></li>');
		});
	},
	searchInit: function(){
		$("#searchBtn").on("click", function(){
			$("#search").addClass("on").find(".search_input").focus();
		});
		$("#searchCancel").on("click", function(){
			$("#search").removeClass("on");
		});
	}
}
